import request from "@/utils/request";

export function getPermissions(data) {
  return request({
    url: "/shop/permissions",
    method: "post",
    data
  });
}

// 获取员工管理列表
// export function getDepartmentData(data) {
//   return request({
//     url: "/shop/department/data",
//     method: "post",
//     data
//   });
// }

// 部门列表删除
export function departmentDel(data) {
  return request({
    url: "/shop/department/delete",
    method: "post",
    data
  });
}

// 获取员工添加/修改部门数据
export function getDepartmengtUpdate(data) {
  return request({
    url: "/shop/department/update",
    method: "post",
    data
  });
}

// 部门删除
export function getDepartmengtDelete(data) {
  return request({
    url: "/shop/department/delete",
    method: "post",
    data
  });
}

// 部门负责人菜单
export function getDepartmengtCharge(data) {
  return request({
    url: "/customer/charge/data",
    method: "post",
    data
  });
}

// 部门负责人菜单
export function getStoreRoles(data) {
  return request({
    url: "/shop/roles/list",
    method: "post",
    data
  });
}

// 部门负责人菜单
export function getDropList(data) {
  return request({
    url: "/shop/user/dropdata",
    method: "post",
    data
  });
}

// 角色数据
export function getRolesData(data) {
  return request({
    url: "/shop/roles/data",
    method: "post",
    data
  });
}

export function getUserList(data) {
  return request({
    url: "/shop/user/list",
    method: "post",
    data
  });
}

// 发送注册验证码
export function sendSmscode(data) {
  return request({
    url: "/shop/send/smscode",
    method: "post",
    data
  });
}

// 新增员工
export function getUserUpdate(data) {
  return request({
    url: "/shop/user/update",
    method: "post",
    data
  });
}

// 删除角色
export function deleteStoreRole(data) {
  return request({
    url: "/shop/store-role/delete",
    method: "post",
    data
  });
}

export function createStoreRole(data) {
  return request({
    url: "/shop/store-role/create",
    method: "post",
    data
  });
}

// 绑定微信
export function wechatUserId(data) {
  return request({
    url: "/shop/wechat_user_id",
    method: "post",
    data
  });
}

// 仓库分组
export function getWarehouseList(data) {
  return request({
    url: "/inquiry/warehouseList",
    method: "post",
    data
  });
}

// 仓库新增修改
export function getWarehouseUpdate(data) {
  return request({
    url: "/inquiry/warehouseEdit",
    method: "post",
    data
  });
}

// 仓库分组列表
// export function getWhGroupList(data) {
//   return request({
//     url: "/shop/warehousegroup/list",
//     method: "post",
//     data
//   });
// }

// 仓库添加修改分组
export function getWhGroupUpdate(data) {
  return request({
    url: "/shop/warehousegroup/update",
    method: "post",
    data
  });
}

// 仓库删除分组
export function WhGroupDelete(data) {
  return request({
    url: "/shop/warehousegroup/delete",
    method: "post",
    data
  });
}

// 仓库删除
export function warehouseDelete(data) {
  return request({
    url: "/inquiry/warehouseDel",
    method: "post",
    data
  });
}

// 仓库分组列表
export function getWhGroupData(data) {
  return request({
    url: "/inquiry/warehouseGroupData",
    method: "post",
    data
  });
}
